package com.example.jni4cpp;

import android.util.Log;

public class JNITest {
    static {
        System.loadLibrary("native-lib");
    }

    public native String stringFromJNI();

    //在jni中调用mylog函数
    public native void logFromJNI(String msg);

    //在jni中调用设置age属性
    public native void setAgeFromJNI(int age);

    public native int getAgeFromJNI();

    //根据关键字顺序查找返回关键字对应角标
    public native int sequenceSearchFromJNI(Integer[] arr, int key);

    //入队
    public native long queuePush(int number);
    //出队
    public native int queueFront(long queue);


    public void mylog(String value) {
        Log.d("TAG", "mylog:" + value);
    }

    public int age = 0;

    public int getAge() {
        return this.age;
    }
}
